            //#include "depthHelper.cginc"
             // GetViewDirect( __vertex_output, ro, rd);
             //float4 screenPos : TEXCOORD1;
            //o.screenPos = ComputeScreenPos(o.vertex);


			/*
            
            Matrix4x4 viewMat = mCamera.worldToCameraMatrix;
            Matrix4x4 projMat = GL.GetGPUProjectionMatrix(mCamera.projectionMatrix, false);
            Matrix4x4 viewProjMat = (projMat * viewMat);
            mat.SetMatrix("_ViewProjInv", viewProjMat.inverse);

            */

            uniform float4x4 _ViewProjInv;
            sampler2D_float _CameraDepthTexture;
            float4x4 _View2World;
            float4 GetWorldPositionFromDepth( float2 uv_depth )
            {
            float depth = SAMPLE_DEPTH_TEXTURE(_CameraDepthTexture, uv_depth);

            #if defined(SHADER_API_OPENGL)
                depth=depth*2.0-1.0;
            #endif
            float4 H = float4(uv_depth.x*2.0-1.0, (uv_depth.y)*2.0-1.0, depth, 1.0);
            float4 D = mul(_ViewProjInv,H);
            return D/D.w;
            }
            /*float3 GetWorldDirect( float2 uv_depth )
            {
            
            float4 H =  float4(uv_depth.x*2.0-1.0, (uv_depth.y)*2.0-1.0, 0.0, 1.0);
            float4 D = mul(_ViewProjInv,H);
            return  D/D.w - _WorldSpaceCameraPos ;
            }  */
            void GetViewDirect(v2f i,out float3 cam, out float3 viewDir)
            {
                cam = _WorldSpaceCameraPos.xyz;
                float3 wpos = GetWorldPositionFromDepth(i.uv);
                viewDir = normalize(wpos - _WorldSpaceCameraPos);
                //viewDir = normalize(GetWorldDirect(i.uv));
				 
            }

            void GetViewDirectNoNormalize(v2f i,out float3 cam, out float3 viewDir)
            {
                cam = _WorldSpaceCameraPos.xyz;
                float3 wpos = GetWorldPositionFromDepth(i.uv);
                
                 viewDir =  wpos - _WorldSpaceCameraPos ;
                //viewDir =  GetWorldDirect(i.uv) ;
				 
            }
              